#include <iostream>
#include <string.h>
using namespace std;
enum direction{forwards,backwards};
int find(char s[],char c,int times=1,direction dir = forwards)
{
    int i = 0;
    bool bIfFind = false; 
    int counter = 0;
    switch(dir)
    {
        case forwards:
            for (i =0; i<strlen(s);i++)
            {
                if(s[i] == c)
                    counter++;
                if(counter == times)
                {
                    bIfFind = true;
                    break;
                }
            }
            if(bIfFind)
               return i;
            else
               return -1;
            break;
        case backwards:
            int counter = 0;
            for (i = strlen(s)-1;i>=0; i--)
            {
                if(s[i] == c)
                    counter++;
                if(counter == times)
                {
                    bIfFind = true;
                    break;
                }
            }
            if(bIfFind)
               return i;
            else
               return -1;
            break;
    }
}

int deal()
{
    char s[256];
    cin.getline(s,256);
    int first = find(s,',');
    int second  = find(s,'.');
    if(first>= 0 && second >=0)
    {
        if(s[first-1] == 'g' && s[first -2] == 'n' && s[first-3] == 'o' && s[second-1] == 'g' && s[second -2] == 'n' && s[second-3] == 'o' )
        {
            int pos = find(s,' ',3,backwards);
            char qiao[] = "qiao ben zhong.";
            for(int i = 0; i <= strlen(qiao);i++ )
                s[pos+1+i] = qiao[i];
            cout<<s<<endl;
        }
        else
            cout<<"Skipped"<< endl;
    }
    else
        cout<<"Skipped" << endl;
}

int main()
{
    int N;
    cin >> N;
    cin.ignore();
    for(int i = 0; i<N; i++)
        deal();
}